package bookExercise;

import java.util.List;
import java.util.stream.Stream;

public class A14anyMatch {
    public static void main(String[] args) {
        List<A14Emplyee> list =A14Emplyee.getEmpList();
        Stream<A14Emplyee> stream =list.stream();
        boolean b = stream.anyMatch(n -> n.getAge() > 25);
        System.out.println("是不是有的员工年龄都大于25岁？"+b);
    }
}
